$(document).ready(function(){
    rsizeWrap();
});

function rsizeWrap(){
    $height=$(window).height()-$("#header").outerHeight()-$("#footer").outerHeight();
    if($("#wrap").outerHeight()<$height){
        $("#wrap").height($height-25);
    }
}